{% extends 'indexBase.html' %}

{% block title %}python管理-源码管理-源码管理系统{% endblock %}
{% block description %}<meta name="description" content="python管理" />{% endblock %}
{% block keywords %}<meta name="keywords" content="python管理" />{% endblock %}
{% block js %}
<script type="text/javascript" src="{{request.basePath}}/js/common.js?{{request.PUBLISH_FLAG}}"></script>
<script type="text/javascript">
  	window.onload = function() {
		var parentCheck = "selectAll";
		var childrenID = "checkboxes";
		addCheckboxClickEvent(parentCheck, childrenID);
	}
</script>
{% endblock %}

{% block content %}
	<table cellSpacing="0" cellPadding="0"  border="0" class="dfgl">
	  <TR>
	    <TD class="top_bottom">&nbsp;
	      <span class="h1">·请您输入查询条件</span>
	    </TD>
	  </TR>
	  <TR>
	    <TD class="mid">
	      <form method="post" id="" action="{{request.basePath}}/index/sourcecode/?type={{request.GET.type}}&traceId={{request.traceId}}">
		<input type="hidden" name="pageNo" value="{{page.pageNo}}" />
		<table  width="100%" border="0" cellpadding="0" cellspacing="0">
		  <tr>
	            <td>
		      <p id="selectFirst" class="pErrorInfo" style="display: none">
			<font color="red">请先选择！</font>
		      </p>
		      {% if message %}
		      <p class="pErrorInfo">
			<font color="red">{{message}}</font>
		      </p>
		      {% endif %}
		      <table width="100%" border="0" cellpadding="0" cellspacing="0" class="infoList">
			<tbody>
			  <tr>
			    <th width="15%">名称</th>
			    <td colspan="3">
			      <input type="text" name="name" value="{{name}}" size="20" 
				     maxlength="20" class="input0" />
			    </td>
			  </tr>
			</tbody>
	    	      </table>
		      <p class="pLeft">
			<input type="submit" value="查询" class="bn_2" />
		      </p>
	    	    </td>
		  </tr>
		</table>
	      </form>
	      
	      <p class="pRight">
		<input type="button" value="增加" class="bn_2" onclick="location.href='{{request.basePath}}/index/sourcecode/create?type={{request.GET.type}}&traceId={{request.traceId}}'" />
		<input type="button" value="删除" class="bn_2"
		       onclick="submitDelete('{{request.basePath}}/index/sourcecode/delete/?type={{request.GET.type}}&traceId={{request.traceId}}', document.forms[1])" />
	      </p>
	      <form method="post" id="" action="{{request.basePath}}/index/sourcecode/delete/?type={{request.GET.type}}&traceId={{request.traceId}}">
		<input type="hidden" name="pageNo" value="{{page.pageNo}}" />
			<table class="list" width="100%" border="0" cellpadding="0" cellspacing="0">
			  <thead>
				<tr>
				  <td class="t2">
				    <input type="checkbox" id="selectAll"/>
				  </td>
				  <th>
				  	序号
				  </th>
				  <th>
				  	名称
				  </th>
				  <th>
				  	项目
				  </th>
				  <th>
				    创建日期
				  </th>
				</tr>
			  </thead>
				<tbody id="checkboxes">
				  {% for item in page.items %}
				  <tr>
				    <td class="t2">
				      <input type="checkbox" name="ids" value="{{item.id}}" />
				    </td>
				    <td class="t2">
					<a href="{{request.basePath}}/index/sourcecode/{{item.id}}?type={{request.GET.type}}&traceId={{request.traceId}}">{{forloop.counter}}</a>
				    </td>
				    <td class="t2">
					<a href="{{request.basePath}}/index/sourcecode/{{item.id}}?type={{request.GET.type}}&traceId={{request.traceId}}">
					  {{item.name}}
					</a>
				    </td>
				    <td class="t2">
					<a href="{{request.basePath}}/index/sourcecode/{{item.id}}?type={{request.GET.type}}&traceId={{request.traceId}}">
					  {{item.project.name}}
					</a>
				    </td>
				    <td class="t2">
				      <a href="{{request.basePath}}/index/sourcecode/{{item.id}}?type={{request.GET.type}}&traceId={{request.traceId}}">
					{{item.createTime}}
				      </a>
				    </td>
				  </tr>
				  {% endfor %}
				</tbody>
		    </table>
	      </form>
			{% include 'submitPage.html' %}
	    </td>
	  </tr>
	  <tr>
            <td class="top_bottom">
              &nbsp;
            </td>
	  </tr>
	</table>
{% endblock %}
